<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<div id="wrap">

	<jsp:include page="common/header.jsp"></jsp:include>

	<div id="container">
    	<div class="content">
			<form action="PostServlet" method="post">
			<div class="notice">
				<p><span>添加新文章</span></p>
			</div>
		
			<div class="post">
			
			<!-- 日期-标题 -->
			<div class="date"></div>
			<h2>标题: <input type="text" name="title"/></h2>
			
			<!-- 信息 -->
			<div class="info">
				<span class="categories">
					<select id="categoryid" name="category">
						<c:forEach items="${categoryList}" var="category">
						<option value="${category.id }">${category.name}
						</option>
						</c:forEach>
					</select>
				</span>
       			<span class="tags"><input type="text" name="tags"/></span>
       			&raquo; 
       			<input class="post-edit-link" type="submit" value="保存"/>
       			<input type="hidden" name="action" value="addPost" />
				<span class="comments"><em>0</em> Comments</span>
			<div class="clear"></div>
			</div>
			
			<!-- 文章内容 -->
			<div class="intro">
				<br/>
			<textarea name="content" class="textarea" cols="80" rows="20"></textarea>
			</div>
			
			</div><!-- post-->
			</form>
    	</div><!-- content-->
    	
        <jsp:include page="sidebar.jsp"></jsp:include>
	</div><!-- #container -->
	
	<jsp:include page="common/footer.jsp"></jsp:include>

</div>